import * as types from './mutationtypes'

const mutations = {
    [types.SET_SONG_LIST] (state, newValue) {
        state.songlist = newValue
    },
    [types.SET_CORRENT_INDEX] (state, newValue) {
        state.currentIndex = newValue
    },
    [types.CURRENT_ADD] (state) {
        state.currentIndex++
    },
    [types.CURRENT_REDUCE] (state) {
        state.currentIndex--
    }
}

export default mutations 